<script data-cfasync="false" src="/cdn-cgi/scripts/5c5dd728/cloudflare-static/email-decode.min.js"></script> 

<script src="/static/js/jquery-2.1.4.min.js"></script>

<script src="/static/js/nav.js" type="text/javascript"></script><!--导航js-->

<script src="/static/layui/layui.js" charset="utf-8"></script>
<script type="text/javascript">
	//注意：导航 依赖 element 模块，否则无法进行功能性操作
	layui.use(['layer', 'element'], function() {
		var element = layui.element,
			$ = layui.jquery,
			layer = layui.layer;
		//…
	});
</script>
<script>
	var kongid = '';
	function right_open_close(s, cls, id) {
		var xieyihost = window.location.protocol + '//' + window.location.host
		var index = layer.load(1, {
			shade: [0.1, '#fff']
		});
		var str = xieyihost + "/static/uploads/Icon/ups.png";
		if (s.children[1].src == str) {
			$("." + cls).css('display', 'none');
			s.children[1].src = "/static/uploads/Icon/down.png";
			s.children[0].innerHTML = "View More ";
			layer.closeAll('loading');
		} else {
			$("." + cls).css('display', 'block');
			s.children[1].src = "/static/uploads/Icon/ups.png";
			s.children[0].innerHTML = "View Less ";
			layer.closeAll('loading');
		}
	}
	function title_sel(id) {
		
		if(id == 'lily34f15aca3e29825bd3ce2e18d487a863'){
			$('.maodian').css({
				top:'-13rem',
			})
		}else{
			$('.maodian').css({
				top:'-86px',
			})
		}
		
		kongid = id;
		document.querySelector("#" + id).scrollIntoView();
		$("#" + id + "1").css('border', '1px solid black');

	}
	//点击空白处隐藏隐藏
	$(document).mouseup(function(e) {
		if (kongid != '') {
			var _con = $('#' + kongid + '1'); // 设置目标区域
			if (!_con.is(e.target) && _con.has(e.target).length === 0) {
				document.getElementById(kongid + '1').style.border = '';
			}
		}
	})
	
</script>
<script type="text/javascript">
	var scrollT = 0;
	var pointT = 0
	var canRun = true;
	var lwidth = $('.body-buttom-left').width(); /*左侧宽度*/
	var biaoH = 0 /*表自身加距上高度*/

	var selstr = new Array();
	selstr['Design_Units'] = new Array();
	selstr['Material'] = new Array();
	selstr['Bore_Dia'] = new Array();
	selstr['Outer_Dia'] = new Array();
	selstr['Width'] = new Array();
	selstr['Seal_Type'] = new Array();

	var controllname = "Mb";

	var num = $('.posit-box')


	// 给表头设置id
	$(".posit-box").each(function() {
		$(this).find('.posit').prop('id', "posit" + $(this).index())
	})
	//给表设置id
	$(".posit-box").each(function() {
		$(this).find('.right-table-content').prop('id', "right-table-content" + $(this).index())
	})
	
	
	if($(window).height() < 851){
		$("#toulist>li").unbind("click");
	}
	
	
	$('.body-buttom').css({
		height: `${$(window).height() - 165}px`,
	})
	$('.body-buttom-right').css({
		width: `${$(window).width() - 230}px`,
		height: `${$(window).height() - 175}px`,
		'overflow': 'auto',
	})
	
	$('.body-buttom-left-body-content').css({
		height: `${$(window).height() - 400}px`,
	})
	
		
	//滚动条滚动时
	var odiv = document.getElementById('odiv')
	odiv.onscroll = function(e) {
		var srccha = odiv.scrollTop - $('.body-buttom').offset().top; /*滚动距离减去(主体距离顶部的距离)*/
		
		//遮盖
		if(srccha > -165.46875){
			$('.cover').css({
				display: 'block',
			})
		}else{
			$('.cover').css({
				display: 'none',
			})
		}
		for (var i = 0; i < num.length; i++) {

			$(`#posit${i}`).css({
				position: 'static',
				width: '1650px',
			});
			biaoH = Math.round($(`#right-table-content${i}`).height() + Math.round($(`#posit${i}`).offset().top))

			if (scrollT > Math.round($(`#posit${i}`).offset().top) - 80 ) {
				$(`#posit${i}`).css({
					position: 'fixed',
					top: '239px',
					width: '1650px',
				})
				if (biaoH < scrollT + 210) {
					$(`#posit${i}`).css({
						position: 'static',
					});
				}
			} else {
				$(`#posit${i}`).css({
					position: 'static',
				});
			}
		}


		// 左边和按钮的固定定位
		if (srccha > -68) {
			$('#tou').css({
				position: 'fixed',
				top: '166px',
				width: `${$(window).width() - 240}px`,
				'z-index': '100',
			})
		} else {

			$('#tou').css({
				position: 'static',
				width: `${$(window).width() - 240}px`,
			})

		}
	}


	//当浏览器大小变化时
	$(window).resize(function() {
		// console.log($(window).height() < 851)
		
		
		if($(window).height() < 851){
			$("#toulist>li").unbind("click");
			
		}
		$('.body-buttom-left-body-content').css({
			height: `${$(window).height() - 175}px`,
		})
		$('.body-buttom').css({
			height: `${$(window).height() - 165}px`,
		})
		$('.body-buttom-right').css({
			width: `${$(window).width() - 230}px`,
			height: `${$(window).height() - 175}px`,
			'overflow': 'auto',
		})

		$('#tou').css({
			width: `${$(window).width() - 240}px`
		})

	});

	//点击筛选
	function onsel(key, s) {

		if (s.parentNode.children[0].style.display == 'block') {
			s.parentNode.children[0].style.display = 'none';
			var index = selstr[key].indexOf($.trim(s.children[0].innerHTML));
			if (index > -1) {
				selstr[key].splice(index, 1);
			}
		} else {
			selstr[key].push($.trim(s.children[0].innerHTML));
			s.parentNode.children[0].style.display = 'block';
		}

		$('#Part_No').val('');


		var tiitleList = $('.body-buttom-titleD')

		if (selstr['Design_Units'].length !=0|| selstr['Material'].length != 0 ||selstr['Bore_Dia'].length != 0 || selstr['Outer_Dia'].length != 0 || selstr['Width'].length != 0 || selstr[
				'Seal_Type'] != 0) {
			$("#all_clear").css('display', 'block');
			$(".viewmore").hide();
			$(".posit-box").hide();
			$(".hang").hide()
			var search = '';
			for (x in selstr) {
				if (selstr[x].length != 0) {
					for (var i = 0; i < selstr[x].length; i++) {
						$(".posit-box").filter(function(index) {
							var zhi = $.trim($("." + x + ":contains('" + selstr[x][i] + "')", this).html()) ;
							if (zhi == selstr[x][i]) {
								return zhi;
							}
						}).show();
						$(".hang").filter(function(index) {
							var zhi = $.trim($("." + x + ":contains('" + selstr[x][i] + "')", this).html()) ;
							if (zhi == selstr[x][i]) {
								return zhi;
							}
						}).show();
						search += x + "='" + selstr[x][i] + "' or ";
					}
				}
			}
			search = search.substr(0, search.length - 3);
			$.post("{:url('" + controllname + "/shaixuan')}", {
				search: search
			}, function(res) {
				$("#toulist").html(res.tou);
			})
			layer.closeAll('loading');
			odiv.scrollTop = 0
		} else {
			// console.log('进false了?')
			$("#all_clear").css('display', 'none');
			layer.load(1, {
				shade: [0.1, '#fff'],
				success: function() {
					setTimeout(function() {
						location.reload();
					}, 1000);
				}
			});
		}
		
		

	}
	
	function clearall() {
		layer.load(1, {
			shade: [0.1, '#fff'],
			success: function() {
				setTimeout(function() {
					location.reload();
				}, 1000);
			}
		});
	}

	function selinput(k, v) {
		var index = layer.load(1, {
			shade: [0.1, '#fff']
		});
		var value = $("input[name='" + k + "']").val();

		$.post("{:url('" + controllname + "/get_input_data')}", {
			value: value,
			v: v
		}, function(res) {

			if (res.status == '0') {
				layer.closeAll('loading');
				layer.msg(res.msg, {
					time: 1000
				});
				$("input[name='" + k + "']").focus();
				var str = '';
				for (var i = 0; i < res.ydata.length; i++) {
					if (res.ydata[i]['num'] != 0) {
						str +=
							"<div><img src='/static/img/check_load.gif' style='display:none;margin-top:5px'><div onclick=onsel('" +
							v + "',this)><span>" + res.ydata[i][v] + "</span><span>(" + res.ydata[i]['num'] +
							")</span></div></div>";
					}
				}
				$("#" + k).html(str);
				return false;
			}
			if (res.status == '1') {
				layer.closeAll('loading');
				var str = '';
				for (var i = 0; i < res.data.length; i++) {
					if (res.data[i]['num'] != 0) {
						str +=
							"<div><img src='/static/img/check_load.gif' style='display:none;margin-top:5px'><div onclick=onsel('" +
							v + "',this)><span>" + res.data[i][v] + "</span><span>(" + res.data[i]['num'] +
							")</span></div></div>";
					}
				}
				$("#" + k).html(str);
			}
			if (res.status == '2') {
				layer.closeAll('loading');
				var str = '';
				for (var i = 0; i < res.ydata.length; i++) {
					if (res.ydata[i]['num'] != 0) {
						str +=
							"<div><img src='/static/img/check_load.gif' style='display:none;margin-top:5px'><div onclick=onsel('" +
							v + "',this)><span>" + res.ydata[i][v] + "</span><span>(" + res.ydata[i]['num'] +
							")</span></div></div>";
					}
				}
				$("#" + k).html(str);
			}
		})

	}
	
	
	
	
	$("#Part_No").keyup(function() {
		var Part_No = $.trim($('#Part_No').val());
		console.log('Part_No:',Part_No)
		if (Part_No != '') {
			$("#all_clear").css('display', 'block');
			console.log(Part_No.toUpperCase())
			Part_No = Part_No.toUpperCase();
			$(".viewmore").hide();
			$(".posit-box").hide();
			$(".hang").hide()
				.filter(function(index) {
					return $(".Product:contains('" + Part_No + "')", this).html();
				}).show();
			$(".posit-box").filter(function(index) {
				return $(".Product:contains('" + Part_No + "')", this).html();
			}).show();
	
		} else {
			if (selstr == '') {
				$("#all_clear").css('display', 'none');
			}
			$(".posit-box").show();
			$(".hang").show()
		}
	
	});
	
</script>


<script type="text/javascript">

//导航 js

  $(function () {

    $("#main-menu").smartmenus({

      subMenusSubOffsetX: 6,

      subMenusSubOffsetY: -8,

    });

  });

  // SmartMenus mobile menu toggle button

  $(function () {

    var $mainMenuState = $("#main-menu-state");

    if ($mainMenuState.length) {

    // animate mobile menu

    $mainMenuState.change(function (e) {

      var $menu = $("#main-menu");

      if (this.checked) {

        $menu.hide().slideDown(250, function () {

          $menu.css("display", "block");

        });

      } else {

        $menu.show().slideUp(250, function () {

          $menu.css("display", "none");

        });

      }

    });

    // hide mobile menu beforeunload

    $(window).bind("beforeunload unload", function () {

      if ($mainMenuState[0].checked) {

        $mainMenuState[0].click();

        }

      });

    }

  });



/*轮播*/



layui.use(["carousel", "form","element",'layer'], function () {

  var carousel = layui.carousel,

      form = layui.form,

      element = layui.element;

  var $ = layui.jquery, layer = layui.layer;

    //图片轮播

   

  var lunbo=carousel.render({

        elem: "#lunbo",

        width: "100%",

        height: "820px",

        interval: 5000,

      });

  carousel.on('change(carofilter)', function(obj){ //监听轮播 

    var screen_width=$(window).width();//屏幕宽度

    if(screen_width<='768'){

        lunbo.reload({ //重置轮播

        elem: '#lunbo',

        width: "100%", //设置容器宽度

        height: '260px',

        interval: 5000,

      });

     $('.pic').css('height','100%');   

    }

  });

    

});

 



/*点击切换语言*/

function lan_qihuan(){

  $("#lan_qihuan").css('display','block');

  $(".li1").css('background-color','#36648A');

  $(".li1 a").css('color','#ffffff');

  $(".li1 .layui-icon-ok").css('display','inline');

  $(".li1 .layui-icon-ok").css('color','#ffffff');

}






$(document).click(function(event){

  var _con = $('.flan_qihuan');

      // 如果点击目标不是input，弹框消失

      if( !_con.is(event.target) ){

          $('#lan_qihuan').css('display','none');

      }

  });



  $(".li2").on({

    mouseover: function () {

       $(".li2").css('background-color','#36648A');

       $(".li2 a").css('color','#ffffff');

       $(".li2 .layui-icon-ok").css('display','inline');

       $(".li2 .layui-icon-ok").css('color','#ffffff');



       $(".li1").css('background-color','#ffffff');

       $(".li1 a").css('color','black');

       $(".li1 .layui-icon-ok").css('display','none');

    },

    mouseout: function () {

       $(".li2").css('background-color','#ffffff');

       $(".li2 a").css('color','black');

       $(".li2 .layui-icon-ok").css('display','none');

      

    }

}); 



  $(".li1").on({

    mouseover: function () {

       $(".li1").css('background-color','#36648A');

       $(".li1 a").css('color','#ffffff');

       $(".li1 .layui-icon-ok").css('display','inline');

       $(".li1 .layui-icon-ok").css('color','#ffffff');



       $(".li2").css('background-color','#ffffff');

       $(".li2 a").css('color','black');

       $(".li2 .layui-icon-ok").css('display','none');

    },

    mouseout: function () {

       $(".li1").css('background-color','#ffffff');

       $(".li1 a").css('color','black');

       $(".li1 .layui-icon-ok").css('display','none');

      

    }

});



  $("#lan_qihuan").on({

    

    mouseout: function () {

       $(".li1").css('background-color','#36648A');

       $(".li1 a").css('color','#ffffff');

       $(".li1 .layui-icon-ok").css('display','inline');

      

    }

});



  

/*搜索*/



var url_str=window.location.pathname; //这是一字符串

var strs= new Array(); //定义一数组

strs=url_str.split("/"); //字符分割

if(strs[1]=='search-result'){

  var issearapi=1;

}else{

  var issearapi=2;

}





  function searsel(){

    var index = layer.load(1, { shade: [0.1,'#fff'] });

    var title = $.trim($('#sear').val());

    if(title==''){

         $("#layui-icon-search").css('display','inline');

         $("#layui-icon-close").css('display','none');

         $("#selinfo").css('display',"none");

         $("#sear").val('');

         $("#selinfo").html('');

         layer.closeAll('loading');

         return false;

    }



      $.post("{:url('index/Es/get_search')}",{searinfo:title},function(res){
      var resdata=res.hits;
      
        if(resdata.total==0){
          layer.closeAll('loading');
            $("#layui-icon-close").css('display','inline');
            return false;
        }else{
          var str='';
            for(var i=0;i<resdata.hits.length;i++){
              if(i<5){
                str += '<div class="sear-tips-result-body"><div class="sear-tips-result-header">';
                str += '<h3><a href="/products/'+resdata.hits[i]['_source']['url']+'/">'+resdata.hits[i]['_source']['Product_Number']+'</a></h3>';
                str += '<span class="sear-tips-result-header-span"><span>In</span> <span>'+resdata.hits[i]['_source']['cname']+'</span></span></div>';
                str += '<div class="sear-tips-result-content">';
                str += '<div class="sear-tips-result-content1">'+resdata.hits[i]['_source']['neirong']+'</div>';
                str += '<div class="sear-tips-result-content2">';
                str += '<img src="'+resdata.hits[i]['_source']['img']+'">';
                str += '</div> <div class="clear"></div></div></div>';
              }

              
            } 
            $('#selinfo').html(str);

            $("#selinfo").css('display',"block");

            $("#layui-icon-close").css('display','inline');

            layer.closeAll('loading');
        }
    })
     

  }





  function closear(){

      $("#sear").val('');

      $("#selinfo").css('display','none');

      $("#selinfo").html('');

      $("#layui-icon-search").css('display','inline');

      $("#layui-icon-close").css('display','none');

  }



  function goout(){

   $("#selinfo").css('display','none');

  }

  function lai(){

     if(document.getElementById("selinfo").innerHTML==''){

       $("#selinfo").css('display','none');

     }else{

       $("#selinfo").css('display','block');

     }

  }


 var retlist='';

    document.onkeydown=function(event){

            

            var e = event || window.event || arguments.callee.caller.arguments[0];


            if(e && e.keyCode==13){ // enter 键

                $("#selinfo").css('display','none');

                sear();  

            }   

  };



 function sear(){

    var title = $.trim($('#sear').val());

        if(title==''){

          $("#layui-icon-search").css('display','inline');

          $("#layui-icon-close").css('display','none');

          $("#selinfo").css('display',"none");

          $("#sear").val('');

          $("#selinfo").html('');

          layer.closeAll('loading');

          return false;

        }

    var v=title.replace(/ /g, '-').replace(/\//g,'-').replace(/\+/g, '-').replace(/\./g, '-');

     if(issearapi=='2'){

        window.open("/sr/"+v.toLowerCase()+"/");

     }else{

        location.href="/sr/"+v.toLowerCase()+"/";

     }  

   } 

</script>



<!-- 站外代码 -->



<!-- Start of LiveChat (www.livechatinc.com) code -->

<script>

    window.__lc = window.__lc || {};

    window.__lc.license = 3911741;

    ;(function(n,t,c){function i(n){return e._h?e._h.apply(null,n):e._q.push(n)}var e={_q:[],_h:null,_v:"2.0",on:function(){i(["on",c.call(arguments)])},once:function(){i(["once",c.call(arguments)])},off:function(){i(["off",c.call(arguments)])},get:function(){if(!e._h)throw new Error("[LiveChatWidget] You can't use getters before load.");return i(["get",c.call(arguments)])},call:function(){i(["call",c.call(arguments)])},init:function(){var n=t.createElement("script");n.async=!0,n.type="text/javascript",n.src="https://cdn.livechatinc.com/tracking.js",t.head.appendChild(n)}};!n.__lc.asyncInit&&e.init(),n.LiveChatWidget=n.LiveChatWidget||e}(window,document,[].slice))

      function liveChat_lily_click(){ /*主动唤起livechat*/

        LiveChatWidget.call('maximize');

      }

</script>

<noscript><a href="https://www.livechatinc.com/chat-with/3911741/" rel="nofollow">Chat with us</a>, powered by <a href="https://www.livechatinc.com/?welcome" rel="noopener nofollow" target="_blank">LiveChat</a></noscript>

<!-- End of LiveChat code -->



<!-- Matomo -->

<script type="text/javascript">

  var _paq = window._paq || [];

  /* tracker methods like "setCustomDimension" should be called before "trackPageView" */

  _paq.push(['trackPageView']);

  _paq.push(['enableLinkTracking']);

  (function() {

    var u="https://lilybearing.matomo.cloud/";

    _paq.push(['setTrackerUrl', u+'matomo.php']);

    _paq.push(['setSiteId', '1']);

    var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];

    g.type='text/javascript'; g.async=true; g.defer=true; g.src='//cdn.matomo.cloud/lilybearing.matomo.cloud/matomo.js'; s.parentNode.insertBefore(g,s);

  })();

</script>

<!-- End Matomo Code -->





<!-- 触脉统计代码-->

 <script>

    (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){

      (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),

      m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)

      })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

    ga('create', 'UA-9102388-1', 'auto'); 

    function getParam(p){

        var match = RegExp('[?&]' + p + '=([^&]*)').exec(window.location.search);

        return match && decodeURIComponent(match[1].replace(/\+/g, ' '));

    }

    var gclid = getParam('gclid');

    ga('set', 'dimension4', gclid );

    ga('send', 'pageview');

</script>



<!-- Event snippet for Livechat(Adwords Tracking) conversion page

In your html page, add the snippet and call gtag_report_conversion when someone clicks on the chosen link or button. -->

<script>

function gtag_report_conversion() {

gtag('event', 'conversion', {

      'send_to': 'AW-1016956908/GBYqCIn4qZMBEOyP9uQD'

  });

  ga('send','event','LiveChat', 'Chat', 'Group ID: {num}');

}

</script>



<!--ga代码开始-->

<span style="font-size: 12pt;">

<script src="https://pv.sohu.com/cityjson?ie=utf-8"></script>

<script type="text/javascript">

  var cookieName= "ipnum";

  var cookieName2= "ipci";

    var ipnumber  =returnCitySN["cip"]+".741";

    var ipcity  = returnCitySN['cname'];

    var cookiePath  = "/";

 

    

    var expirationTime = 172800*15;                           

    expirationTime = expirationTime * 1000;

 

    var date = new Date();

    var dateTimeNow = date.getTime();

    date.setTime(dateTimeNow + expirationTime);

 

    var expirationTime = date.toUTCString();

 

    document.cookie = cookieName+"="+ipnumber+"; expires="+expirationTime+"; path="+cookiePath;

    document.cookie = cookieName2+"="+ipcity+"; expires="+expirationTime+"; path="+cookiePath; 

  

  (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){

      (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),

      m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)

      })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

    ga('create', 'UA-9102388-1', 'auto'); 



    var ipnumbercity = ipnumber+ipcity;

    ga('set', 'dimension5', ipnumbercity );

    ga('send', 'ipnumbercity');

  

</script>

</span>

<!--ga代码结束-->



<script>

var LC_API=LC_API||{};LC_API.on_chat_started=function(){

  gtag_report_conversion();

};

</script>

<script type="text/javascript">function setCookie(name,value,days){var date=new Date();date.setTime(date.getTime()+(days*24*60*60*1000));var expires=";expires="+date.toGMTString();document.cookie=name+"="+value+expires+";path=/"}if(gclid){var gclsrc=getParam('gclsrc');if(!gclsrc||gclsrc.indexOf('aw')!==-1){setCookie('gclid',gclid,90)}}</script>

<script type="text/javascript">function Base64(){_keyStr="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";this.encode=function(input){var output="";var chr1,chr2,chr3,enc1,enc2,enc3,enc4;var i=0;input=_utf8_encode(input);while(i<input.length){chr1=input.charCodeAt(i++);chr2=input.charCodeAt(i++);chr3=input.charCodeAt(i++);enc1=chr1>>2;enc2=((chr1&3)<<4)|(chr2>>4);enc3=((chr2&15)<<2)|(chr3>>6);enc4=chr3&63;if(isNaN(chr2)){enc3=enc4=64}else{if(isNaN(chr3)){enc4=64}}output=output+_keyStr.charAt(enc1)+_keyStr.charAt(enc2)+_keyStr.charAt(enc3)+_keyStr.charAt(enc4)}return output};this.decode=function(input){var output="";var chr1,chr2,chr3;var enc1,enc2,enc3,enc4;var i=0;input=input.replace(/[^A-Za-z0-9\+\/\=]/g,"");while(i<input.length){enc1=_keyStr.indexOf(input.charAt(i++));enc2=_keyStr.indexOf(input.charAt(i++));enc3=_keyStr.indexOf(input.charAt(i++));enc4=_keyStr.indexOf(input.charAt(i++));chr1=(enc1<<2)|(enc2>>4);chr2=((enc2&15)<<4)|(enc3>>2);chr3=((enc3&3)<<6)|enc4;output=output+String.fromCharCode(chr1);if(enc3!=64){output=output+String.fromCharCode(chr2)}if(enc4!=64){output=output+String.fromCharCode(chr3)}}output=_utf8_decode(output);return output};_utf8_encode=function(string){string=string.replace(/\r\n/g,"\n");var utftext="";for(var n=0;n<string.length;n++){var c=string.charCodeAt(n);if(c<128){utftext+=String.fromCharCode(c)}else{if((c>127)&&(c<2048)){utftext+=String.fromCharCode((c>>6)|192);utftext+=String.fromCharCode((c&63)|128)}else{utftext+=String.fromCharCode((c>>12)|224);utftext+=String.fromCharCode(((c>>6)&63)|128);utftext+=String.fromCharCode((c&63)|128)}}}return utftext};_utf8_decode=function(utftext){var string="";var i=0;var c=c1=c2=0;while(i<utftext.length){c=utftext.charCodeAt(i);if(c<128){string+=String.fromCharCode(c);i++}else{if((c>191)&&(c<224)){c2=utftext.charCodeAt(i+1);string+=String.fromCharCode(((c&31)<<6)|(c2&63));i+=2}else{c2=utftext.charCodeAt(i+1);c3=utftext.charCodeAt(i+2);string+=String.fromCharCode(((c&15)<<12)|((c2&63)<<6)|(c3&63));i+=3}}}return string}};</script>

<script type="text/javascript">var cb=function(){var l=document.createElement("link");l.rel="stylesheet";l.href="https://www.lily-bearing.com/wp-content/themes/theme/front/dist/styles/font-awesome.min.css";var h=document.getElementsByTagName("head")[0];h.parentNode.insertBefore(l,h)};var raf=requestAnimationFrame||mozRequestAnimationFrame||webkitRequestAnimationFrame||msRequestAnimationFrame;if(raf){raf(cb)}else{window.addEventListener("load",cb)};</script>



<script>
  var userip=<?php echo "'".$_SERVER["REMOTE_ADDR"]."'";?>;
  $(".email").click(function(){

    ga('send','event','PC_Email','click::Email','Email');

  });



  $(".logo").click(function(){

    ga('send','event','PC_topnavigation','click::logo','nav_logo')

  });



  $("#gform_submit_button_1").click(function(){

    var names=$.trim($("input[name='name']").val());

    var emails=$.trim($("input[name='email']").val());

    var b=new Base64();

    ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'ipnum':userip})

  });



  $("#gform_submit_button_2").click(function(){

    var names=$.trim($("input[name='name']").val());

    var emails=$.trim($("input[name='email']").val());

    var b=new Base64();

    ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'ipnum':userip})

  });



  $("#gform_submit_button_3").click(function(){

    var names=$.trim($("input[name='name']").val());

    var emails=$.trim($("input[name='email']").val());

    var b=new Base64();

    ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'ipnum':userip})

  });

  $("#gform_submit_button_4").click(function(){

    var names=$.trim($("input[name='name']").val());

    var emails=$.trim($("input[name='email']").val());

    var company=$.trim($("input[name='company']").val());

    var country=$.trim($("select[name='country'] option:selected").val());

    var main_products=$.trim($("input[name='main_products']").val());

    var comments=$.trim($("textarea[name='comments']").val());

    var b=new Base64();

    ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'dimension3':b.encode(company),'dimension4':b.encode(country),'dimension5':b.encode(main_products),'dimension6':b.encode(comments),'ipnum':userip})

  });



  $("#gform_submit_button_5").click(function(){

    var names=$.trim($("input[name='name']").val());

    var numbers=$.trim($("input[name='phone']").val());

    var emails=$.trim($("input[name='email']").val());

    var b=new Base64();

    ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'dimension3':b.encode(numbers),'ipnum':userip})

  });

    var stop=0;$(".menu-item").click(function(){var classchar=$(this).attr('class');if(stop==0){classchar=classchar.substr(classchar.length-5,5);dada(classchar)}stop=1});var stop1=0;$(".cat-item").click(function(){if(stop1==0){var arr1=new Array('Ball Bearings','Ceramic Bearings','Needle Roller Bearings','inless Steel Bearings','Tapersd Roller Bearings','Custom Bearings');var v1=$(this).find("a").first().html();var aa=arr1.indexOf(v1);if(aa>=0){ga('send','event','PC_rightonlinecatalog',v1,'Lv1_'+v1)}else{var v2=$(this).parents('.current-cat-ancestor').find("a").first().html();var ll=3;if($(this).children('ul').length!=0||$(this).parent('.current-cat-parent').length!=0||$(this).parent('.current-cat-ancestor').length!=0){var ll=2}if(!v2){var v2=$(this).parents('.current-cat').find("a").first().html();var ll=2}ga('send','event','PC_rightonlinecatalog',v2,'Lv'+ll+'_'+v1)}}stop1=1});

  </script>


